package com.runchamp;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentStatePagerAdapter;

/**
 * Created by Omri on 08/01/2015.
 */
public class PersonalZoneCollectionAdapter extends FragmentStatePagerAdapter {
    public PersonalZoneCollectionAdapter(FragmentManager fm) {
        super(fm);
    }

    @Override
    public Fragment getItem(int i) {
        switch (i) {
            case 0:
                return new AchievementsActivity();
            case 1:
                return new HistoryRaces();
        }
        return null;
    }

    @Override
    public int getCount() {
        return 2;
    }

    @Override
    public CharSequence getPageTitle(int position) {
        switch (position) {
            case 0:
                return "My Achievements";
            case 1:
                return "My Races History";
        }
        return "";
    }
}
